﻿<%@ Page Title="实习单位管理 - 湖北师范大学顶岗实习管理系统" Language="C#" MasterPageFile="~/e/Master/Iframe.Master" AutoEventWireup="true" CodeBehind="List.aspx.cs" Inherits="Chizx.Web.companys.List" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MasterIframeHead" runat="server">
    <script src="/js/CheckBox.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(function () {
            $(".list_table").colResizable({
                liveDrag: true,
                gripInnerHtml: "<div class='grip'></div>",
                draggingClass: "dragging",
                minWidth: 30
            });

        });
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MasterIframeHolder1" runat="server">
    <div id="search_bar" class="mt10">
        <div class="box">
            <div class="box_border">
                <div class="box_top"><b class="pl15">搜索</b></div>
                <div class="box_center pt10 pb10">
                    <table class="form_table" border="0">
                        <tr>
                            <td>
                                <span class="fl">
                                    <div class="select_border">
                                        <div class="select_containers ">
                                            <asp:DropDownList ID="scOption" runat="server" class="select">
                                                <asp:ListItem Value="zcom_name">企业名称</asp:ListItem>
                                                <asp:ListItem Value="zcom_address">企业地址</asp:ListItem>
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                </span>
                            </td>
                            <td>
                                <asp:TextBox ID="txtKeyword" runat="server" CssClass="input-text lh25"></asp:TextBox>
                                <asp:Button ID="btnSearch" runat="server" Text="查询" OnClick="btnSearch_Click" class="btn btn82 btn_search" value="查询" />
                            </td>
                            <%if (Session["UserDegree"].ToString() == "A3" || Session["UserDegree"].ToString() == "A0")
                              { %>
                            <td>
                                <a href="/companys/Add.aspx" class="btn btn82 btn_add" style="display:block; width:47px; color:#000;">新增</a>
                            </td>
                            <%} %>
                            <td>
                                <asp:Button ID="btnDelete" runat="server" Text="删除" OnClick="btnDelete_Click" class="btn btn82 btn_del" value="删除" /></td>
                            <td></td>
                        </tr>
                    </table>
                </div>
            </div>
        </div>
    </div>
    <div id="table" class="mt10" style="margin-bottom: 40px;">
        <div class="box span10 oh">
            <asp:GridView ID="gridView"  CssClass="list_table" BorderStyle="None" CellPadding="0" GridLines="None" rules="none" BorderWidth="0px" runat="server" AllowPaging="True" Width="100%" OnPageIndexChanging ="gridView_PageIndexChanging"
                     DataKeyNames="zcom_id" OnRowDataBound="gridView_RowDataBound"
                    AutoGenerateColumns="False"  RowStyle-HorizontalAlign="Center" OnRowCreated="gridView_OnRowCreated">
                    <Columns>
                    <asp:TemplateField ControlStyle-Width="30" HeaderText="选择"    >
                                <ItemTemplate>
                                    <asp:CheckBox ID="DeleteThis" onclick="javascript:CCA(this);" runat="server" />
                                </ItemTemplate>

<ControlStyle Width="30px"></ControlStyle>
                            </asp:TemplateField> 
                            
		<asp:BoundField DataField="zcom_id" HeaderText="序号" SortExpression="zcom_id" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_name" HeaderText="企业名称" SortExpression="zcom_name" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_address" HeaderText="地址" SortExpression="zcom_address" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_desc" HeaderText="描述简介" SortExpression="zcom_desc" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_applynum" HeaderText="申请人数" SortExpression="zcom_applynum" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_passnum" HeaderText="已招收" SortExpression="zcom_passnum" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_neednum" HeaderText="需求人数" SortExpression="zcom_neednum" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
		<asp:BoundField DataField="zcom_createdate" HeaderText="创建时间" SortExpression="zcom_createdate" ItemStyle-HorizontalAlign="Center"  > 
<ItemStyle HorizontalAlign="Center"></ItemStyle>
                        </asp:BoundField>
                        <asp:TemplateField HeaderText="企业状态" SortExpression="zcom_status">
                            <EditItemTemplate>
                                <asp:TextBox ID="TextBox1" runat="server" Text='<%#Eval("zcom_status").ToString()=="c0"?"在招中...":(Eval("zcom_status").ToString()=="c1"?"已结束":"未知状态")%>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%#Eval("zcom_status").ToString()=="c0"?"在招中...":(Eval("zcom_status").ToString()=="c1"?"已结束":"未知状态")%>'></asp:Label>
                            </ItemTemplate>
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:TemplateField>
                            
                            <asp:HyperLinkField HeaderText="详细" ControlStyle-Width="50" DataNavigateUrlFields="zcom_id" DataNavigateUrlFormatString="Show.aspx?id={0}"
                                Text="详细"  >
<ControlStyle Width="50px"></ControlStyle>
                        </asp:HyperLinkField>
                            <asp:HyperLinkField HeaderText="编辑" ControlStyle-Width="50" DataNavigateUrlFields="zcom_id" DataNavigateUrlFormatString="Modify.aspx?id={0}"
                                Text="编辑"  >
<ControlStyle Width="50px"></ControlStyle>
                        </asp:HyperLinkField>
                            <asp:TemplateField ControlStyle-Width="50" HeaderText="删除"   Visible="false"  >
                                <ItemTemplate>
                                    <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
                                         Text="删除"></asp:LinkButton>
                                </ItemTemplate>

<ControlStyle Width="50px"></ControlStyle>
                            </asp:TemplateField>
                        </Columns>
                <EditRowStyle BorderStyle="None" Wrap="False" />
                <EmptyDataRowStyle BorderStyle="None" Wrap="False" />
                <FooterStyle CssClass="tr" Wrap="False" />
                <HeaderStyle CssClass="" BorderStyle="None" Wrap="False" />
                <PagerStyle CssClass="pagination" Wrap="False" />
                <RowStyle CssClass="tr" />
                <SelectedRowStyle CssClass="tr" Wrap="False" />
                <SortedAscendingCellStyle Wrap="False" />
            </asp:GridView>
        </div>
    </div>
</asp:Content>
